package com.lancoo.klgcourseware.entity;

import android.text.TextUtils;

import java.io.Serializable;

/**
 * Created by pengmi on 2018/11/8.
 * Description:英语词汇类发音训练模型
 */

public class WordArticulation implements Serializable {

    //知识点编码
    private String KlgCode;
    //知识点类型编码
    private String KlgType;
    //知识点名称
    private String KlgName;
    //英式音标
    private String UN_phonetic;
    //英式音标音频路径
    private String UN_voice;
    //美式音标
    private String US_phonetic;
    //美式音标音频路径
    private String US_voice;
    //音节
    private String Syllable;

    public String getKlgCode() {
        return KlgCode;
    }

    public void setKlgCode(String klgCode) {
        KlgCode = klgCode;
    }

    public String getKlgType() {
        return KlgType;
    }

    public void setKlgType(String klgType) {
        KlgType = klgType;
    }

    public String getKlgName() {
        return KlgName;
    }

    public void setKlgName(String klgName) {
        KlgName = klgName;
    }

    public String getUN_phonetic() {
        return UN_phonetic;
    }

    public void setUN_phonetic(String UN_phonetic) {
        this.UN_phonetic = UN_phonetic;
    }

    public String getUN_voice() {
        if(!TextUtils.isEmpty(UN_voice)){
            UN_voice= UN_voice.replace("//////","/").replace("/////","/").replace("////","/").replace("///","/").replace("//","/");
            if(TextUtils.equals("/",UN_voice.substring(0,1))){
                UN_voice=UN_voice.substring(1);
            }
        }
        return UN_voice;
    }

    public void setUN_voice(String UN_voice) {
        this.UN_voice = UN_voice;
    }

    public String getUS_phonetic() {
        return US_phonetic;
    }

    public void setUS_phonetic(String US_phonetic) {
        this.US_phonetic = US_phonetic;
    }

    public String getUS_voice() { if(!TextUtils.isEmpty(UN_voice)){
        US_voice= US_voice.replace("//////","/").replace("/////","/").replace("////","/").replace("///","/").replace("//","/");
        if(TextUtils.equals("/",US_voice.substring(0,1))){
            US_voice=US_voice.substring(1);
        }
    }
        return US_voice;
    }

    public void setUS_voice(String US_voice) {
        this.US_voice = US_voice;
    }

    public String getSyllable() {
        return Syllable;
    }

    public void setSyllable(String syllable) {
        Syllable = syllable;
    }
}
